import  service  from '.';

export const addCartApi = (userid: string, proid: string, num?: number) => service.post('/cart/add', {
  userid, proid, num: num || 1
})


export const getCartListApi = (userid: string) => service.post('/cart/list', { userid })


export const updateStatusApi = (cartid: string, flag: boolean) => service.post('/cart/selectone', { cartid, flag })
export const checkAllApi = (userid: string, type: boolean) => service.post('/cart/selectall', { userid, type })
